package com.feixiang.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.feixiang.bean.UserInfo;
import com.feixiang.dao.UserInfoDao;
import com.feixiang.service.UserInfoService;

@Service
public class UserInfoServiceImpl implements UserInfoService {
	@Autowired
	private UserInfoDao userInfoDao;
/*	@Override
	@Transactional 
	public boolean addUserInfo(UserInfo userInfo) {
		return this.userInfoDao.addUserInfo(userInfo)>0?true:false;
	}
	@Override
	@Transactional
	public List<UserInfo> getUserInfoList() {
		try {
			return this.userInfoDao.getAllUserInfos();
		} catch (Exception e) {
			System.out.println("ҵ���߼��� UserInfoServiceImpl.getUserInfoList()�����쳣!");
			return null;
		}
	}*/
	@Transactional
	public UserInfo getUserInfoById(Integer userId) {
		return this.userInfoDao.getUserInfoById(userId);
	}

}
